import org.newdawn.slick.GameContainer;
import org.newdawn.slick.Graphics;
import org.newdawn.slick.SlickException;
import org.newdawn.slick.state.BasicGameState;
import org.newdawn.slick.state.StateBasedGame;

/**
 * game play
 * @author Akshay
 *
 */
public class GamePlayState extends BasicGameState {
	
	int stateID = 0;
	
	Entity testEntity;
	
	public GamePlayState(int ID){
		stateID = ID;
	}

	@Override
	public void init(GameContainer container, StateBasedGame game) throws SlickException {
		testEntity = new Entity("test");
		testEntity.addComponent(new TopDownMovementComponent("tesMover"));
		testEntity.addComponent(new WindComponent("testWind"));
		testEntity.addComponent(new BoxRenderComponent("testRender"));
		
	}

	@Override
	public void render(GameContainer container, StateBasedGame game, Graphics g) throws SlickException {
		testEntity.render(container, game, g);
	}

	@Override
	public void update(GameContainer container, StateBasedGame game, int delta) throws SlickException {
		testEntity.update(container, game, delta);		
	}

	@Override
	public int getID() {
		return stateID;
	}

}
